﻿
/*
NAILSUPERSTORE ® COMPANY
 
[HISTORY]
Created By  	: NGUYEN VAN TY
Created Date	: 28/02/2010
Modified By     :
Modified Date   :
Note            :

*/

using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
using CommonTagTime.DataAccess;
using CommonTagTime.ModelObject;
namespace CommonTagTime.Business
{
    public class busCountryAreaCategory
    {
        //------------------------------------------------
        //FIELD TABLE
        //------------------------------------------------
       
        public const string AreaCategoryId = "AreaCategoryId";
        public const string CountryID = "CountryID";     
        public const string SortOrder = "SortOrder";    
        public const string CurrentPage = "CurrentPage";
        public const string PageSize = "PageSize";     
        public const string TotalRecords = "TotalRecords";
        public const string Condition = "Condition";


        private daoCountryAreaCategory _objDao;
        //------------------------------------------------
        //PUBLIC
        //------------------------------------------------
        public busCountryAreaCategory()
        {
            _objDao = new daoCountryAreaCategory();
        }
        public bool Insert(CountryAreaCategory objData)
        {
            return _objDao.Insert(objData);
        }
        public bool Insert(CountryAreaCategoryCollection lstData)
        {
            foreach (CountryAreaCategory objCate in lstData)
            {
                _objDao.Insert(objCate);
            }
            return true;
        }
        public CountryAreaCategoryCollection GetByCategoryId(int cate)
        {           
            return _objDao.GetByCategoryId(cate);
        }
        public bool DeleteByCountryId(int countryId)
        {
            return _objDao.DeleteByCountryId(countryId);
        }
        public CountryAreaCategoryCollection GetByCountryId(int country)
        {
            return _objDao.GetByCountryId(country);
        }
    }

}

